home *** CD-ROM | disk | FTP | other *** search
/ Aminet 50 / Aminet 50 (2002)(GTI - Schatztruhe)[!][Aug 2002].iso / Aminet / disk / bakup / DSrestore.lha / DSrestore / DSrestore.doc < prev    next >
Text File  |  2002-06-19  |  6KB  |  157 lines

  1. This is a standalone command line application to restore archives in the
  2. DiskSalv stream format. I wrote the first version because after
  3. reformatting a partition which I previously backuped to a stream archive
  4. I found out that the "restore" function didn't work exactly as I expected.
  5. In fact all versions of DiskSalv I tried restore a stream archive by
  6. putting all(!) the contents of the stream in the target dir - no structure
  7. is left.
  8.  
  9. This is a really dissatisfying misfeature of an otherwise fine program.
  10. You also notice this only eventually because DiskSalv keeps an
  11. exclusive lock on the target dir, so you cannot even control the
  12. progress by peeking into the directory.
  13.  
  14. So I set off to write a better restore routine for myself and here it is.
  15. When I had finished I thought that there may be others who would be
  16. thankful for a program like this, so I decided to refine
  17. it a bit. The DiskSalv stream format supports all major AmigaDOS object
  18. types. To be perfect, it only needs to support user and group bits, but
  19. whoever needs this, may be better off with an ixemul application like
  20. "tar" anyway.
  21.  
  22. The commandline pattern is:
  23. DSrestore STREAM/A,TARGET,DEBUG/S,LOGFILE/K
  24.  
  25. STREAM: archive stream to be read
  26.  
  27. TARGET: target dir where the archive contents will be written to. Can
  28.         be omitted, the default is the current dir. When the target
  29.         directory can not be written to for what reason ever, the
  30.         program falls back to the SYS: dir. (I had no better idea,
  31.         really. :-) So be careful.
  32.  
  33. DEBUG:  turn on lots of debugging output, which may be interesting if
  34.         something goes wrong.
  35.  
  36. LOGFILE: log the written files to this file. Default is no output. This
  37.      is "no output", not the file "no output". ;-)
  38.  
  39.  
  40. This program comes with full source, including Dave Haynie's
  41. ds_stream.h, which is according to the file header in the public domain.
  42. I cleaned up the source a lot, but I think it's still quite ugly in some
  43. parts.
  44.  
  45. Still a big TODO: Fix handling of softlinks in archive; restore links
  46. to absolute paths because this is the way to go under AmigaOS.
  47.  
  48. Here comes the history straight from the RCS log, edited to be language
  49. consistent.
  50.  
  51. RCS file: RCS/DSrestore.c
  52. Working file: DSrestore.c
  53. head: 3.3
  54. branch:
  55. locks: strict
  56.         obw: 3.3
  57. access list:
  58. symbolic names:
  59.         analyze: 2.1.1
  60. keyword substitution: kv
  61. total revisions: 16;    selected revisions: 16
  62. description:
  63. restoring of DiskSalv stream archive.
  64. ----------------------------
  65. revision 3.3    locked by: obw;
  66. date: 2002/04/30 00:53:27;  author: obw;  state: Exp;  lines: +9 -4
  67. LOGFILE parameter now operational. :-)
  68. ----------------------------
  69. revision 3.2
  70. date: 2002/04/30 00:03:16;  author: obw;  state: Exp;  lines: +17 -58
  71. cleaned up source; replaced numerical errors with macros;
  72. removed surplus routines; removed old variables; minor style
  73. corrections.
  74. ----------------------------
  75. revision 3.1
  76. date: 2002/04/29 00:50:56;  author: obw;  state: Exp;  lines: +18 -29
  77. important memory allocations handled by pools; foundation for better
  78. error handling. Now finally frees all memory at exit again!
  79. ----------------------------
  80. revision 2.10
  81. date: 2002/04/28 23:48:03;  author: obw;  state: Exp;  lines: +9 -9
  82. removed lots of exit()s.
  83. ----------------------------
  84. revision 2.9
  85. date: 2002/04/28 23:39:57;  author: obw;  state: Exp;  lines: +39 -32
  86. more memory cleanup
  87. ----------------------------
  88. revision 2.8
  89. date: 2001/12/30 20:45:45;  author: obw;  state: Exp;  lines: +1 -0
  90. FIX: mem leak fixed, now StdErr is closed when a command line parse error
  91. occurs
  92. ----------------------------
  93. revision 2.7
  94. date: 2001/12/30 20:34:33;  author: obw;  state: Exp;  lines: +1 -0
  95. FIX: small memory leak fixed.
  96. BUG: still a mem leak of 260 bytes at startup.
  97. ----------------------------
  98. revision 2.6
  99. date: 2001/12/30 20:10:11;  author: obw;  state: Exp;  lines: +61 -27
  100. all clib-memory allocations substituted by AmigaOS functions.
  101. ----------------------------
  102. revision 2.5
  103. date: 2001/03/03 14:17:32;  author: obw;  state: Exp;  lines: +2 -2
  104. forgotten variable corrected
  105. ----------------------------
  106. revision 2.4
  107. date: 2001/03/03 14:14:42;  author: obw;  state: Exp;  lines: +24 -24
  108. Error messages go to stderr now. Less SASlib-code.
  109. ----------------------------
  110. revision 2.3
  111. date: 2001/02/28 22:19:10;  author: obw;  state: Exp;  lines: +48 -33
  112. faster file copy, better memory handling.
  113. FIX: correct memory allocation while copying.
  114. FIX: defect files in archive are handled correctly.
  115. ADD: stderr no open.
  116. ----------------------------
  117. revision 2.2
  118. date: 2001/02/28 00:13:19;  author: obw;  state: Exp;  lines: +63 -32
  119. quicker copying, lots of verbose output.
  120. ----------------------------
  121. revision 2.1
  122. date: 2001/02/26 23:50:24;  author: obw;  state: Exp;
  123. branches:  2.1.1;
  124. first version with full RCS and bumprev.
  125. ----------------------------
  126. revision 2.1.1.3
  127. date: 2001/02/28 00:20:51;  author: obw;  state: Exp;  lines: +1 -1
  128. errors corrected. final list-only version.
  129. ----------------------------
  130. revision 2.1.1.2
  131. date: 2001/02/27 22:46:07;  author: obw;  state: Exp;  lines: +42 -18
  132. working view-only version.
  133. ----------------------------
  134. revision 2.1.1.1
  135. date: 2001/02/27 00:01:59;  author: obw;  state: Exp;  lines: +59 -54
  136. "analyze-only" branch for testing of file format.
  137. =============================================================================
  138.  
  139. DSrestore (C) 2001-2002 Oliver B. Warzecha <obw@amarok.ping.de>
  140.  
  141.     This file is part of DSrestore.
  142.  
  143.     DSrestore is free software; you can redistribute it and/or modify
  144.     it under the terms of the GNU General Public License as published by
  145.     the Free Software Foundation; either version 2 of the License, or
  146.     (at your option) any later version.
  147.  
  148.     DSrestore is distributed in the hope that it will be useful,
  149.     but WITHOUT ANY WARRANTY; without even the implied warranty of
  150.     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  151.     GNU General Public License for more details.
  152.  
  153.     You should have received a copy of the GNU General Public License
  154.     along with DSrestore; if not, write to the Free Software
  155.     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  156.  
  157.